import request from '@/utils/request'

// 查询运输单列表
export function listDan(query) {
  return request({
    url: '/system/dan/list',
    method: 'get',
    params: query
  })
}

// 查询运输单详细
export function getDan(publishId) {
  return request({
    url: '/system/dan/' + publishId,
    method: 'get'
  })
}

// 新增运输单
export function addDan(data) {
  return request({
    url: '/system/dan',
    method: 'post',
    data: data
  })
}

// 修改运输单
export function updateDan(data) {
  return request({
    url: '/system/dan',
    method: 'put',
    data: data
  })
}

// 删除运输单
export function delDan(publishId) {
  return request({
    url: '/system/dan/' + publishId,
    method: 'delete'
  })
}

// 导出运输单
export function exportDan(query) {
  return request({
    url: '/system/dan/export',
    method: 'get',
    params: query
  })
}